home *** CD-ROM | disk | FTP | other *** search
- /*
- File: RgnShpe.h
-
- Contains: RgnShape class, private to ODShape.
-
- Written by: Jens Alfke
-
- Copyright: 1993-94 by Apple Computer, Inc., all rights reserved.
-
- Change History (most recent first):
-
- <3> 12/5/94 jpa Code review cleanup. [1203923]
- <2> 8/8/94 jpa Added Outset method [1178690]
- <1> 6/15/94 jpa first checked in
- --------Moved to SOM project and rearranged-----
- <7> 5/9/94 jpa Enable polygon clipper and GX support
- [1162090]
- <6> 3/15/94 MB Changes to support SCpp/ASLM builds,
- #1150864.
- <5> 2/17/94 JA Declare XMPPolygon as struct, not class.
- <4> 2/16/94 JA Include new AltPoint.h.
- <3> 2/10/94 JA Stop using ptrs to member fns.
- <2> 2/9/94 JA Renamed from ShapePrv.h --> ShapePvM.h
- <6> 2/7/94 JA Further tigerings.
- <5> 2/3/94 JA Tiger Team Makeover!
- <4> 1/31/94 JA XMPRealShape no longer derives from
- XMPAbsShape. Other API improvements.
- <3> 11/24/93 VL Rolled back changes as ASLM build breaks
- the THINK build.
- <2> 11/23/93 VL Made this work with ASLM.
- <1> 11/23/93 JA first checked in
- */
-
-
- #ifndef _RGNSHPE_
- #define _RGNSHPE_
-
- #ifndef _ODTYPES_
- #include "ODTypes.h"
- #endif
-
- #ifndef _PLFMDEF_
- #include "PlfmDef.h"
- #endif
-
- #ifndef _REALSHPE_
- #include "RealShpe.h" /* Base class*/
- #endif
-
-
- //==============================================================================
- // RgnShape
- //==============================================================================
-
- class RgnShape :public RealShape {
- public:
-
- RgnShape( ODGeometryMode mode );
- virtual ~RgnShape( );
-
- ODVMethod ODSize Purge(ODSize size); // Can't purge rgn!
-
- ODVMethod void GetBoundingBox( ODRect *bounds );
- ODVMethod RealShape* SetRectangle( const ODRect *rect );
- ODVMethod void CopyPolygon( ODPolygon& );
- ODVMethod RealShape* SetPolygon( const ODPolygon& );
-
- ODVMethod ODBoolean IsSameAs(RealShape* compareShape);
- ODVMethod ODBoolean IsEmpty( );
- ODVMethod ODBoolean ContainsPoint(ODPoint point);
- ODVMethod ODBoolean IsRectangular( );
- ODVMethod ODBoolean HasGeometry( );
-
- ODVMethod void SetPlatformShape( ODGraphicsSystem, ODPlatformShape );
- ODVMethod RealShape* Copy( ); // Really returns an ODRgnShape*
-
- ODVMethod RealShape* Transform(Environment*, ODTransform* transform);
- ODVMethod RealShape* Outset(ODCoordinate distance);
- ODVMethod RealShape* Subtract(RealShape* diffShape);
- ODVMethod RealShape* Intersect(RealShape* sectShape);
- ODVMethod RealShape* Union(RealShape* sectShape);
-
- protected:
- ODVMethod void InitQDRegion( );
- ODVMethod gxShape CopyGXShape( );
-
- virtual RealShape* Clear( ); // Just clear w/o replacing
-
- ODPolygon fPolygon; // Cached equivalent polygon
- };
-
-
- #endif /*_RGNSHPE_*/